package Sensors;

import java.util.Date;

import format.Event;

public abstract class Sensor {

	Event event;
	
	public Sensor (int value, String location) {
		event = new Event();

		event.setValue(""+value);
		event.setLocation(location);
		event.setTimestamp(new Date());
		event.setExpiry(new Date(System.currentTimeMillis()+4000));
	}
	
	public Event getEvent() {
		return event;
	}
}
